Repository navigation
Rename AvailableEntityTypes to EmbeddedEntityTypes - #38565
Conversation
❌ PR checklist incompleteThis PR cannot be merged until the following are addressed on its linked issue:
The fields live on the linked issue in the Shipping project (open the issue → right sidebar → Projects). After you set them, re-run this check (or push a commit) — issue/project changes do not re-trigger it automatically. Maintainers can bypass this check by adding the |
Code Review ✅ Approved 🟡 Medium riskRemoving OpenSearch RRF pipeline management and checks shifts hybrid fusion to callers, so callers still relying on server normalization could rank results differently. Renames VerificationRules No rules evaluated Functional validation Not enabledAuto-approval Not enabledFor more verification details, comment OptionsDisplay: compact → Showing compact verification results. Comment with these commands to change the behavior for this request:
Was this helpful? React with 👍 / 👎 | Powered by Gitar — free for open source |
Describe your changes:
No issue: a rename, plus the removal of code nothing calls any more.
I renamed
AvailableEntityTypestoEmbeddedEntityTypesand gave its members names that say what they are, because the old names hid three things:LISTreally means "entity types that get vector embeddings". Nothing in the name says so.LISTandSEThold the same types and differ only in casing (SETis lowercased), which the names do not show.dataAssetEmbeddingsandontologyTerms). A caller that wanted "what chat search can reach" took the whole list and got the ontology types too. That is how Collate's chat search ended up offering ontology types as filters.The new class, in the same package:
LISTALLDATA_ASSET_CHUNK_TYPES(lowercased set)DATA_ASSETS(list, original casing)ALLminus ontology terms: exactly thedataAssetEmbeddingsmembersSET,isVectorIndexable(type)isEmbedded(type)ALLDATA_ASSET_CHUNK_TYPES.contains(...)isDataAsset(type)DATA_ASSETSAvailableEntityTypesis deleted, with no deprecated wrapper. The lowercase sets are now private to the class.This PR also removes the hybrid RRF search pipeline code. OpenMetadata created, refreshed and checked an OpenSearch search pipeline,
hybrid-rrf, that nothing in OpenMetadata ran. Its only caller, Collate's hybrid search, now fuses its keyword and semantic results itself (Collate PR #8899). #38517 reverted this deletion to keep Collate compiling; it comes back here unchanged. Gone:HYBRID_PIPELINE_NAME,buildHybridRrfPipelineDefinition,getHybridRrfPipelineDefinitionand theensure,update,checkandusesHybridSearchPipelinemethods ofOpenSearchVectorServiceandSearchRepository, with their calls on vector service start, in the Search Indexing preflight, on search settings save and in the deployment status. Its embeddings step now just says "Embeddings are working correctly." on both engines.getHybridWeights()stays, and so does thesearchPipelineconfiguration key (now described as ignored), so existing configuration files still load.Type of change:
High-level design:
Every use moved, in main and test code. Two callers needed more than a rename:
RecreateWithEmbeddingscounted how many data-asset types a reindex run covers by lowercasing the run's types and looking them up in the lowercased set. It now asksisDataAssetfor each type the run names and counts distinct lowercased names. The result is the same, and a new test checks that one type named in two casings does not stand in for a missing type.AbstractVectorIndexServicekeeps a per-run checklist (stagedExpectedTypes) and ticks off types as they finish, keyed by the lowercased name. A case-insensitive lookup can say whether one type is on the checklist, but not whether every type has finished, which needs the whole set of keys. So it keeps a lowercased copy ofDATA_ASSETSas a constant, at the one place that needs it.VectorEmbeddingHandler's lifecycle types becomeSet.copyOf(DATA_ASSETS), which is the same set it built by hand before.Merge order. Everything this PR waited for has merged: Collate PR #8922, #38415, #38517 and Collate PR #8899. It is the last PR of the hybrid search chain.
Uses that #38415 and #38517 added are switched too, in the merge of
main:EmbeddingEnricher,PartitionWorker,AbstractVectorIndexService,RecreateWithEmbeddings,OpenMetadataOperations, and the testsRecreateWithEmbeddingsTest,ElasticSearchVectorServiceTestandVectorChunkIndexIT(SET.forEachbecomesALL.forEach, the same types).Decision record. No new record. The rename's rule is in the class Javadoc and enforced by
EmbeddedEntityTypesConsistencyTest. Amended: ADR:2026-11-23-the-hybrid-rrf-pipeline-leaves-openmetadata (v2: the deletion landed) and ADR:2026-11-20-elasticsearch-and-opensearch-share-one-vector-index-service (v5: hybrid search is no longer OpenSearch-only; it namesEmbeddedEntityTypes.DATA_ASSETS). The Guard line of ADR:2026-11-23-ontology-terms-have-dedicated-search-indexes names the renamed test.Tests:
Use cases covered
dataAssetEmbeddings.Unit tests
EmbeddedEntityTypesTest(new):DATA_ASSETSisALLwithout the two ontology types; the lookups ignore case and rejectnulland non-embedded types.EmbeddedEntityTypesConsistencyTest(renamed fromAvailableEntityTypesConsistencyTest): now comparesDATA_ASSETSwith the alias members in their original casing, which is stricter than the old lowercased comparison, and checks that ontology types are embedded but are not data assets.RecreateWithEmbeddingsTest: moved toALL, plus the two-casings case above.OpenSearchVectorServiceTest,SearchRepositoryBehaviorTest,ReindexingOrchestratorTestandSystemRepositoryEmbeddingsValidationTest, and the pipeline scenario ofVectorEmbeddingIntegrationIT.Backend integration tests
Local Java test run: PASSED
b24edf9fefd1(baseorigin/main)--scope full).The block above is from the previous head. On the current head (
mainmerged in atc6f53f84304), run locally:mvn install -DskipTests -pl openmetadata-service -am: passed.org.openmetadata.service.searchand its subpackages, plusSearchRepository*,SystemRepository*,SystemResource*,RecreateWithEmbeddingsTest,OpenMetadataOperations*,EmbeddedEntityTypes*, the bulk sink tests andReindexingOrchestratorTest: 227 classes, 3472 tests, 0 failed, 0 skipped.test-compileofopenmetadata-integration-tests: passed. The ITs themselves were not run locally.mainbuilt against this branch (mvn install -DskipTests, without the UI and dist modules) and its integration tests compiled: passed. That build used ai-platformmain, as Collate CI does.Ingestion integration tests
Playwright (UI) tests
Manual testing performed
None: no behaviour change; the unit tests above cover each moved caller.
UI screen recording:
Not applicable: backend refactor with no UI change.
Checklist:
I have read the CONTRIBUTING document.
My PR title is
Fixes <issue-number>: <short explanation>My PR is linked to a GitHub issue via
Fixes #<issue-number>above.I have commented on my code, particularly in hard-to-understand areas.
For JSON Schema changes: I updated the migration scripts or explained why it is not needed.
For a UI feature or feature task: as part of PR creation, I ran the PR build in Docker with sample data and embedded a verified GitHub-hosted recording plus build/health evidence above (or explained why this requirement is not applicable).
I have added tests (unit / integration / Playwright as applicable) and listed them above.
Self-review: I reviewed the final diff against
REVIEW.md(thepr-checklistskill runs it) and fixed every 🔴 finding, or answered it on the line below.Decision check: if this PR decides something the next contributor could undo — a schema field, REST path or format another component or repo must agree with, a new default or limit, an ordering that must hold, or a rule stated only in this description — it adds a record under
docs/decisions/(see itsREADME.md). This description is gone fromgit logafter the squash-merge.I have added tests around the new logic.